InstallPrinter Example Script

These are just assembled from stuff elsewhere, including the simple
example scripts from Microsoft's Script Center or generated by the
Scriptomatic program. See the follwing URLs:
* http://www.microsoft.com/technet/scriptcenter/Default.asp
* http://www.microsoft.com/technet/scriptcenter/tools/wmimatic.asp

The purpose is to prove that you too can quickly and easily script
the installation of any printer and driver you need (provided you
can acquire the drivers and get the right information, of course!).

Here's how:
1.) Extract the drivers to a known (i.e. not temporary) directory
    and identify the .INF file which installs them.
2.) Setup the printer as you want to see it installed.
3.) Run 'QueryPrinters.vbs' to get all the information as the
    computer sees it.
4.) Now comes the hard part: you need to determine which values
    you need, and plug them into your own copy of 'InstallPrinter.vbs'.
    Some sections (e.g. installing a TCP/IP printer port) may be
    completely unnecessary. YMMV...
5.) Go to a clean machine, extract the drivers to the path you
    configured in the script, and TEST, TEST, TEST!
6.) Put the driver files and this script into your software package,
    logon script, or whatever your destination is.

( Oh, and keep in mind that if all you want to do is connect to a
  queue on a networked Windows server, you only need two lines! See
  Microsoft's example 'Add a Printer Connection' at this URL:
  http://www.microsoft.com/technet/scriptcenter/printing/ScrPrn01.asp )

You can modify and distribute this script as you like, per the GNU
Public License included in the license.txt file (or online at
http://www.gnu.org/copyleft/gpl.html). Let me know if you make any
improvements!

  Eric W. Wallace (e@ewall.org)
  4 Sept. 2003
  For other related information go to http://ewall.org/
